package com.xmg.design23.d8_decorate;

/**
 * @description: 鸡蛋类  具体装饰者类
 * @Author: mazhongqing
 * @Date: 2021/3/31 11:29
 */
public class Egg extends Garnish{

    public Egg(FastFood fastFood){
        super(fastFood,1,"鸡蛋");
    }

    public float cost() {
        return getPrice() + getFastFood().cost();
    }

    public String getDesc() {
        return super.getDesc() + getFastFood().getDesc();
    }
}
